# Replication Material for Article "How Parties React to Voter Transitions"
# Tarik Abou-Chadi & Lukas F. Stoetzer

## Replication Files
 
- 01_MainText.R: Replicates Tables & Figures from Main Text 
- 02_Apendix.R: Replicates Tables & Figures from Appendix  

Both files can be compiled into a report using the cmd rmarkdown::render("analysis.R", "pdf_document") or RStudio

## Data & function Files

- pty_dat_wweights.Rdata: Contains data.frame DT with variables for main analysis 

- pty_dat_mat.Rdata: Contains Weighting Matrices WL (for Net Loss), WD (for Distance), WNGH (for ideological Neighbors). TRANS contains voter-loss transition between party pairs
- pty_dat_ww_dyd.Rdata: Data in Dyadic-format

- fun_panel.R: Contains functions to estimate clustered standard errors

